package com.ssy.lingxi.member.merchant.controller.feign;

import com.ssy.lingxi.common.response.PageData;
import com.ssy.lingxi.common.response.Wrapper;
import com.ssy.lingxi.member.merchant.api.model.vo.inner.request.MemberSalesFindUserIdVO;
import com.ssy.lingxi.member.merchant.api.model.vo.inner.request.MemberSalesReportOrderCountFeignVO;
import com.ssy.lingxi.member.merchant.api.model.vo.inner.response.MemberSalesFeignPageQueryVO;
import com.ssy.lingxi.member.merchant.service.mobile.IMobileMemberSalesService;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import javax.validation.Valid;
import java.util.List;

/**
 * 业务员小程序--远程调用
 * @author 郑小翠
 * @version 2.02.18
 * @date 2022-03-24
 */
@RestController
@RequestMapping("/member/feign/mobile/wechat/applet/sales")
public class MobileMemberSalesFeignController {

    @Resource
    IMobileMemberSalesService iMobileMemberSalesService;

    /**
     * 根据业务员Id查询下级会员信息
     *
     * @param pageVO 查询条件
     * @return 返回下级会员信息
     */
    @RequestMapping(value = "/findByUserId", method = RequestMethod.POST)
    public Wrapper<PageData<MemberSalesFeignPageQueryVO>> getSalesList(@RequestBody @Valid MemberSalesFindUserIdVO pageVO) {
        return iMobileMemberSalesService.getSalesList(pageVO);
    }

}
